
package com.jf.cloud.supplier.service;

import com.jf.cloud.supplier.dto.SupplierBankCardDTO;
import com.jf.cloud.supplier.vo.SupplierBankCardVO;

import java.util.List;

/**
 * 银行卡信息
 *
 * @author zz
 * @date 2022-03-14 17:04:32
 */
public interface SupplierBankCardService {
    /**
     * 批量新增结算银行账户
     * @param supplierBankCardDTOList
     * @param supplierId
     */
    void insertBatch(List<SupplierBankCardDTO> supplierBankCardDTOList, Long supplierId);

    /**
     * 根据店铺id获取银行卡列表
     * @param supplierId
     * @return
     */
    List<SupplierBankCardVO> listBySupplierId(Long supplierId);

    /**
     * 根据银行卡id删除银行卡信息
     * @param supplierBankCardId
     * @param supplierId
     */
    void deleteBySupplierBankCardId(Long supplierBankCardId, Long supplierId);

    /**
     * 批量新增结算银行账户并提交开店申请
     * @param supplierBankCardDTOList
     * @param supplierId
     */
    void insertBatchAndSubmitApply(List<SupplierBankCardDTO> supplierBankCardDTOList, Long supplierId);

    /**
     * 更新店铺银行卡信息
     * @param supplierBankCardDTO 银行卡信息
     * @param supplierId 店铺id
     */
    void updateBySupplierId(SupplierBankCardDTO supplierBankCardDTO, Long supplierId);

    /**
     * 设置银行卡为主账号
     * @param supplierBankCardId
     * @param supplierId
     */
    void setPrimaryBySupplierId(Long supplierBankCardId, Long supplierId);

    /**
     * 设置银行卡不为主账号
     * @param supplierBankCardId
     * @param supplierId
     */
    void setNotPrimaryBySupplierId(Long supplierBankCardId, Long supplierId);

    /**
     * 保存单个银行卡信息
     * @param supplierBankCardDTO
     * @param supplierId
     */
    void insertBySupplierId(SupplierBankCardDTO supplierBankCardDTO, Long supplierId);

    /**
     * 根据银行卡id获取银行卡信息
     * @param supplierBankCardId
     * @return
     */
    SupplierBankCardVO getBySupplierBankCardId(Long supplierBankCardId);

    /**
     * 根据银行卡id与店铺id获取银行卡信息
     * @param supplierBankCardId
     * @param supplierId
     * @return
     */
    SupplierBankCardVO getBySupplierBankCardIdAndSupplierId(Long supplierBankCardId, Long supplierId);
}
